package com.jd.platform.gobrs.client.dispatcher;

import cn.hutool.cache.Cache;
import com.jd.platform.gobrs.client.manager.CacheManager;
import com.jd.platform.gobrs.common.model.CacheSupplier;

/**
 * @program: gobrs
 * @description: Gobrs 统一类
 * @author: sizegang
 * @create: 2022-01-08 22:11
 **/
public interface GCacheBuilder {

    CacheManager dispatch(Integer cacheHandlerType);


    Object getCache(String key);

    Object getCache(String key, CacheSupplier cacheSupplier);

    Object getCacheAuto(String key);

    Object getCacheAuto(String key, CacheSupplier cacheSupplier);

    boolean setCache(String key, Object value);

    boolean setCacheAuto(String key, Object value);

    boolean isHotKey(String key);


}
